package com.ape.mapsa.service;

import java.util.List;

import com.ape.mapsa.model.Role;
import com.ape.mapsa.model.Session;
import com.ape.mapsa.model.User;
import com.ape.mapsa.model.UserRole;

public interface IUserService {

	/**
	 * Add User
	 * 
	 * @param User
	 *            user
	 */
	public void addUser(User user);

	/**
	 * Update User
	 * 
	 * @param User
	 *            user
	 */
	public void updateUser(User user);

	/**
	 * Delete User
	 * 
	 * @param User
	 *            user
	 */
	public void deleteUser(User user);

	/**
	 * Get User
	 * 
	 * @param int User Id
	 */
	public User getUserByEmail(String email);

	/**
	 * Get User List
	 * 
	 * @return List - User list
	 */
	public List<User> getUsers();

	/**
	 * Login User
	 * 
	 * @param User
	 *            user
	 */
	public User login(User user);

	/**
	 * Gets all defined user roles
	 * 
	 * @return
	 */
	public List<Role> getAllRoles();

	public List<UserRole> getAllUserRoles(User user);

	public void removeUserRoles(User selectedUser);

	public User getById(Long id);

	public void addSession(Session session);

	public Session getSessionById(String id);

	public void updateSession(Session userActiveSession);

}
